package com.example.robertluozizhao.framecollectdemo.activity;

import android.content.Intent;
import android.os.Bundle;
import androidx.annotation.Nullable;
import androidx.appcompat.app.AppCompatActivity;
import android.view.View;

import com.example.robertluozizhao.framecollectdemo.R;

import butterknife.ButterKnife;
import butterknife.OnClick;

/**
 * Created by Lzz on 8/9/2019.
 */

public class AnimationActivity extends AppCompatActivity {


    @Override
    protected void onCreate(@Nullable Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_animation);
        ButterKnife.bind(this);
        initView();
    }

    private void initView() {

    }

    @Override
    public void onBackPressed() {
//        super.onBackPressed();
        finish();
        overridePendingTransition(R.anim.anim_activity_enter,R.anim.anim_activity_out);
    }

    @Override
    protected void onDestroy() {
        super.onDestroy();
    }

    @OnClick({R.id.btn_view_animation, R.id.btn_value_animation, R.id.btn_fragment_animation})
    public void onViewClicked(View view) {
        switch (view.getId()) {
            case R.id.btn_view_animation:
                Intent intent = new Intent(this,ViewAnimationActivity.class);
                startActivity(intent);
                break;
            case R.id.btn_value_animation:
                Intent intent1 = new Intent(this,ValueAnimationActivity.class);
                startActivity(intent1);
                break;
            case R.id.btn_fragment_animation:
                startActivity(new Intent(this,FragmentEnterAnimationActivity.class));
                break;
        }
    }
}
